package il.ac.braude.sona.infogui;

import il.ac.braude.sona.database.ChangeRequest;
import il.ac.braude.sona.strings.Resources;

import java.awt.Dimension;
import java.awt.Toolkit;

public class ChangeRequestInfoFrame extends InfoFrame {

	public ChangeRequestInfoFrame(ChangeRequest req) {
		super(Resources.Strings.RequestInfoTitle);
		for (String f : req.fields)
			addInfoRow(f ,req.getValue(f));
		Dimension dim = Toolkit.getDefaultToolkit().getScreenSize();
		pack();
		setLocation(dim.width/2 - getWidth()/2, dim.height/2 - getHeight()/2);
		setVisible(true);
	}

}
